#include <iostream>
using namespace std;
int main()
{
	long N;
	cin >> N;
	if(0 <= N && N <10){
		cout << 1 << endl;
	}else if(10 <= N && N < 100){
		cout << 2 << endl;
	}else if(100 <= N && N < 1000){
		cout << 3 << endl;
	}else if(1000 <= N && N < 10000){
		cout << 4 << endl;
	}else if(10000 <= N && N < 100000){
		cout << 5 << endl;
	}else if(100000 <= N && N < 1000000){
		cout << 6 << endl;
	}else if(1000000 <= N && N < 10000000){
		cout << 7 << endl;
	}else if(10000000 <= N && N < 100000000){
		cout << 8 << endl;
	}
	return 0;
}